{extend name="$BASE_POPUP_FORM" /}
{block name="body"}

<div class="box-content">

    <div class="control-row col-2">
        <div class="control-group">
            <label class="control-label">注册类型</label>
            <div class="controls">
                <select name="reg_type" id="reg_type" class="form-control">
                    <option value="1">手机号注册</option>
                    <option value="2">邮箱号注册</option>
                </select>
            </div>
        </div>
        <div class="control-group">
            <label class="control-label">用户名</label>
            <div class="controls">
                <input type="text" id="username" name="username" class="form-control"/>
            </div>
        </div>
        <div class="control-group">
            <label class="control-label">手机号</label>
            <div class="controls">
                <input type="text" id="phone" name="phone" class="form-control"/>
            </div>
        </div>
        <div class="control-group">
            <label class="control-label">邮箱</label>
            <div class="controls">
                <input type="text" id="email" name="email" class="form-control"/>
            </div>
        </div>
        <div class="control-group">
            <label class="control-label">推荐上级用户</label>
            <div class="controls">
                <input id="pid" name="pid" data-ui="combosearch"
                       data-options="{valueField:'id',textField:'username',showList:true,matchFields:['username'],data:user_data,searchWin:openSearchWin}"
                       class="form-control"/>
            </div>
        </div>
        <div class="control-group">
            <label class="control-label">登录密码</label>
            <div class="controls">
                <input type="text" name="password" class="form-control" value="dx123456" placeholder="请输入密码"/>
            </div>
        </div>
        <div class="control-group">
            <label class="control-label">交易密码</label>
            <div class="controls">
                <input type="text" name="pay_password" class="form-control"  value="123456" placeholder="请输入交易密码"/>
            </div>
        </div>
    </div>
</div>

{/block}

{block name="script"}
<script type="text/javascript">
  
var user_data ={$user_list};
    function openSearchWin(){
        var url = getURL('member/select_user','','member');
        openBarWinParent('选择用户', 500, 600, url, function (data) {
            $("#pid").setValue(data);
        }, ['选定', '取消']);
    }
</script>
{/block}


